package org.itzheng.yuezhi.real.main;

import android.content.Intent;
import android.os.Bundle;
import android.util.Log;

import org.itzheng.yuezhi.base.BaseActivity;
import org.itzheng.yuezhi.constant.HttpUrl;
import org.itzheng.yuezhi.utils.MyOkHttp;

import java.util.HashMap;

public class MainActivity extends BaseActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {

        super.onCreate(savedInstanceState);
//        setContentView(R.layout.activity_main);
//        test();
        startActivity(new Intent(this, ContentActivity.class));
        finish();
    }

    private void test() {
        String url = HttpUrl.WX_ARTICLE_CATEGORY;
        HashMap<String, Object> hashMap = new HashMap();
        hashMap.put("key", "143a0cc4a21c8");
        MyOkHttp.getInstance().getUrl(url, hashMap, new MyOkHttp.RequestCallBack() {
            @Override
            public void onFailure(Exception httpException, String describe) {
                Log.i("okhttp", "onFailure=" + describe.toString());
            }

            @Override
            public void onSuccess(String result) {
                Log.i("okhttp," + Thread.currentThread().getName(), "onSuccess=" + result.toString());

            }
        });
    }
}
